/**
 * Copyright (c) 2025 Bytedance Ltd. and/or its affiliates
 * 
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * 
 *     http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 **/

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: system-ui;
}

.site-header {
  background: #fff;
  padding: 1rem;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.site-header a {
  text-decoration: none;
  color: inherit;
}

.site-header h1 {
  margin: 0;
  font-size: 1.5rem;
  transition: color 0.2s;
}

.site-header h1:hover {
  color: #666;
}

main {
  flex: 1;
  margin-top: 5rem;
  margin-bottom: 4rem;
  padding: 2rem;
  text-align: center;
}

.site-footer {
  background: #f5f5f5;
  padding: 1rem;
  text-align: center;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  box-shadow: 0 -2px 4px rgba(0,0,0,0.1);
}

.site-footer p {
  margin: 0;
  color: #666;
}

.not-found-go-to-home {
  display: inline-block;
  margin-top: 2rem;
  padding: 0.8rem 1.6rem;
  background: #007bff;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  transition: background 0.2s;
}

.not-found-go-to-home:hover {
  background: #0056b3;
}

.home-go-products-link {
  display: inline-block;
  margin-top: 2rem;
  padding: 0.8rem 1.6rem;
  background: #28a745;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  transition: background 0.2s;
}

.home-go-products-link:hover {
  background: #218838;
}

.product-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 2rem;
  padding: 2rem;
}

.product-card {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  overflow: hidden;
  transition: transform 0.2s;
  cursor: pointer;
}

.product-card:hover {
  transform: translateY(-4px);
}

.product-card .product-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.product-card .product-name {
  padding: 1rem;
  font-size: 1.2rem;
  font-weight: bold;
}

.product-card .product-price {
  padding: 0 1rem 1rem;
  color: #28a745;
  font-weight: bold;
  font-size: 1.1rem;
}

.product-detail {
  width: 50%;
  padding: 2rem;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.product-detail .product-image {
  width: 100%;
  height: 400px;
  object-fit: cover;
  border-radius: 4px;
}

.product-detail .product-name {
  font-size: 2rem;
  margin: 1rem 0;
}

.product-detail .product-price {
  font-size: 1.5rem;
  color: #28a745;
  margin-bottom: 1rem;
}

.product-detail .product-quantity {
  color: #6c757d;
  margin-bottom: 1rem;
}

.product-detail .product-description {
  line-height: 1.6;
  color: #212529;
}

.product-not-found {
  text-align: center;
  padding: 4rem;
  color: #dc3545;
}

.admin-portal-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin: 2rem 0;
}

.admin-portal-links > a {
  padding: 1rem 2rem;
  background: #3498db;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  transition: 0.3s;
}

.admin-portal-links > a:hover {
  background: #2980b9;
  transform: translateY(-2px);
}

.admin-portal-links > a span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.home-go-wish-list {
  display: inline-block;
  padding: 10px 20px;
  background-color: #3498db;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  margin: 20px 0;
  transition: background-color 0.3s;
}

.home-go-wish-list:hover {
  background-color: #2980b9;
}

.product-container {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}

.product-detail button {
  background: #2196f3;
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  margin-top: 20px;
  transition: background 0.3s;
  display: block;
  text-align: center;
  width: 100%;
}

.product-detail button:hover {
  background: #1976d2;
}
